package com.htc.callcare.infrastructure;

import java.io.File;

import android.media.MediaRecorder;

import com.htc.callcare.viewcontroller.Popup_Call;


public class globalVar {
	public static String rootDir = "/sdcard/HTCCallRecord/";
	public static String recordDir = "/sdcard/HTCCallRecord/Record/";
	public static String voiceMailDir = "/sdcard/HTCCallRecord/VoiceMail/";
	public static String logTab = "thuutai";
	public static String AMR = "AMR";
	public static String THREE_GPP = "THREE_GPP";
	public static String MP4 = "MP4";
	public static String mp4Type = ".mp4";
	public static String amrType = ".amr";
	public static String three_gppType = ".3gp";
	public static String incoming = "Incomming";
	public static String outgoing = "Outgoing";
	public static String unknown = "unknown";
	public static final String FORMAT_DAY = "yyyy-MM-dd"; 
	public static String voiceMail = "voiceMail";
	public static void makeDir() {
		createDirIfNotExist(rootDir);
		createDirIfNotExist(recordDir);
		createDirIfNotExist(voiceMailDir);
		
	}
	
	public static boolean createDirIfNotExist(String path){
		boolean result = true;
		File file = new File(path);
		if (!file.exists()) {
			try {
				file.mkdir();
				result = true;
			} catch (Exception e) {
				// TODO: handle exception
				result = false;
			}
		}
		return result;
	}
	
	

}
